package com.yuan.algorithms.practice201511;

import java.util.Scanner;

/**
 * @author YouYuan
 * <br>E-mail:1265161633@qq.com
 * <br>创建时间：2015年11月21日 上午10:44:19
 * <br>说明:
 */
public class 求最小公倍数 {

	static Scanner in = new Scanner(System.in);
	public static void main(String[] args) {
		while(in.hasNext()) {
			int a = in.nextInt();
			int b = in.nextInt();
			System.out.println(lcm(a, b));
		}
	}
	private static int lcm(int a, int b) {
		return a*b/gcd(a, b);
	}

	private static int gcd(int a, int b) {
		int c = 0;
		while(b != 0) {
			c = a % b;
			a = b;
			b = c;
		}
		return a;
	}

}
